Skip to content

Fro 10 connexion utilisateur#27

Merged
pierrick-fonquerne merged 3 commits intodevelopfrom
FRO-10-Connexion-utilisateur
Jan 12, 2026
Merged

Fro 10 connexion utilisateur#27
pierrick-fonquerne merged 3 commits intodevelopfrom
FRO-10-Connexion-utilisateur

Conversation

@pierrick-fonquerne
Copy link
Copy Markdown
Owner

No description provided.

Backend implementation:
- Add POST /api/auth/login endpoint
- JWT token generation with claims (userId, email, pseudo, role)
- Password verification with Argon2
- Account suspension check (403 Forbidden)
- MustChangePassword flag support
- Email normalization (lowercase, trim)
- Secure error messages (no user enumeration)
- Structured logging for auth events

New files:
- IJwtService, JwtService, JwtSettings
- LoginRequest, LoginResponse, UserInfo DTOs
- GetByEmailWithRoleAsync in IUserRepository

Tests:
- 6 unit tests for LoginAsync
- 8 integration tests for POST /api/auth/login
Add frontend authentication with:
- AuthContext for global auth state and localStorage persistence
- LoginForm component with validation and error handling
- LoginPage with accessibility (RGAA) compliance
- authService.login() for API communication
- Unit tests for AuthContext, LoginForm, LoginPage (180 tests total)

Handles MustChangePassword flag (feature placeholder).
- Add DashboardPage placeholder with welcome message
- Update Header with user avatar and dropdown menu
- Redirect to /dashboard after successful login
- Add tests for DashboardPage (9 tests)
- Update Header tests for authenticated state (17 tests)
@vercel
Copy link
Copy Markdown

vercel bot commented Jan 12, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Review Updated (UTC)
fantasyrealm-character-manager Ready Ready Preview, Comment Jan 12, 2026 9:00am

@pierrick-fonquerne pierrick-fonquerne merged commit 21ab261 into develop Jan 12, 2026
7 checks passed
@pierrick-fonquerne pierrick-fonquerne deleted the FRO-10-Connexion-utilisateur branch January 12, 2026 09:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant